﻿<%@ Page Title="" Language="VB" MasterPageFile="~/AMLO/MasterPageAMLO.master" AutoEventWireup="false" CodeFile="Amlo1_05_9.aspx.vb" Inherits="AMLO_Amlo1_05_9" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <script type="text/javascript">
        $(document).ready(function () {
            Sys.WebForms.PageRequestManager.getInstance().add_endRequest(EndRequestHandler);
            $("input[id$=txtDateStart]").datepicker($.extend({}, $.datepicker.regional['th'], {
                yearAddToDisplay: 543,
                dateFormat: 'dd/mm/yy',
                showOn: "button",
                buttonImage: "../img/calendar.gif",
                buttonImageOnly: true
            }));

            $("input[id$=txtDateEnd]").datepicker($.extend({}, $.datepicker.regional['th'], {
                yearAddToDisplay: 543,
                dateFormat: 'dd/mm/yy',
                showOn: "button",
                buttonImage: "../img/calendar.gif",
                buttonImageOnly: true
            }));

            function EndRequestHandler(sender, args) {
                $("input[id$=txtDateStart]").datepicker($.extend({}, $.datepicker.regional['th'], {
                    yearAddToDisplay: 543,
                    dateFormat: 'dd/mm/yy',
                    showOn: "button",
                    buttonImage: "../img/calendar.gif",
                    buttonImageOnly: true
                }));

                $("input[id$=txtDateEnd]").datepicker($.extend({}, $.datepicker.regional['th'], {
                    yearAddToDisplay: 543,
                    dateFormat: 'dd/mm/yy',
                    showOn: "button",
                    buttonImage: "../img/calendar.gif",
                    buttonImageOnly: true
                }));

            }

        });

        var hasSubmitted = 0;
        function NoDoubleSubmit() {
            var divMsg = document.getElementById('Processing');
            if (hasSubmitted == 0) {
                hasSubmitted = 0;
                divMsg.style.display = 'block';
                return true;
            }
            return false;
        }

        var prm = Sys.WebForms.PageRequestManager.getInstance();

        prm.add_initializeRequest(InitializeRequest);
        prm.add_endRequest(EndRequest);

        function InitializeRequest(sender, args) {
            $get('ContentPlaceHolder1_UpdatePanel1').style.cursor = 'wait';
        }

        function EndRequest(sender, args) {
            $get('ContentPlaceHolder1_UpdatePanel1').style.cursor = 'auto';
        }


    </script>
            <table style="width:100%;" >
                <tr>
                    <td align="right" valign="top">
                        <asp:Label ID="lblBranch" runat="server">Upload Excel ข้อมูลธุรกรรม</asp:Label>
                    </td>
                    <td align="left" valign="top">
                        <asp:FileUpload ID="fileUpload1" runat="server" CssClass="control" />
                    </td>
                </tr>
                <tr>
                    <td align="right" valign="top">
                        <asp:Label ID="lblYear" runat="server">Upload Excel ข้อมูลเจ้าของบัญชีร่วมฝั่งผู้โอน</asp:Label>
                    </td>
                    <td align="left" valign="top">
                        <asp:FileUpload ID="fileUpload2" runat="server" CssClass="control" />
                    </td>
                </tr> 
                <tr>
                    <td align="right" valign="top">
                        <asp:Label ID="Label4" runat="server">Upload Excel ข้อมูลเจ้าของบัญชีร่วมฝั่งผู้รับโอน</asp:Label>
                    </td>
                    <td align="left" valign="top">
                        <asp:FileUpload ID="fileUpload3" runat="server" CssClass="control" />
                    </td>
                </tr>
                <tr>
                    <td colspan="6" style="text-align: right">
                        <asp:Button ID="btnUpload" runat="server" CssClass="control" Text="นำเข้าระบบ" 
                            Width="100px" ClientInstanceName="btnUpload" />
                        <asp:Button ID="btnCancel" runat="server" CssClass="control" Text="ยกเลิก" 
                            Width="80px" />
                    </td>
                </tr>
                <tr>
                    <td colspan="6" style="text-align: center">
                        <asp:Label ID="lblMsg" runat="server" CssClass="control" Font-Bold="True" 
                            Font-Size="XX-Large" ForeColor="Red" Height="35px" Text="ไม่พบข้อมูล" 
                            Visible="False" Width="170px"></asp:Label>
         <SPAN id="Processing" style="DISPLAY: none">
 <img src="../img/icon/ajax-loader.gif" alt="Please wait" />
            กรุณารอสักครู่ ระบบกำลังค้นหาข้อมูล...
  </SPAN>
                    </td>
                </tr>
                <tr>
                    <td colspan="6">
                        <asp:GridView ID="grdAmlo" runat="server" AllowPaging="True" 
                            AutoGenerateColumns="False" CellPadding="4" ForeColor="#333333" 
                            style="margin-right: 0px; margin-bottom: 0px;" Width="100%">
                            <RowStyle BackColor="#FFFBD6" ForeColor="#333333" />
                            <Columns>
                                <asp:BoundField DataField="P3_TRANS_DATE" HeaderText="วันที่ทำธุรกรรม" DataFormatString="{0:dd/MM/yyyy}">
                                    <ItemStyle HorizontalAlign="Center" Width="80px" />
                                </asp:BoundField>
                                <asp:BoundField DataField="TOTAL" HeaderText="จำนวน" DataFormatString="{0} รายการ">
                                    <ItemStyle HorizontalAlign="Center" Width="80px" />
                                </asp:BoundField>
                            </Columns>
                            <FooterStyle BackColor="#990000" Font-Bold="True" ForeColor="White" />
                            <PagerSettings Mode="NumericFirstLast" />
                            <PagerStyle BackColor="#FFCC66" CssClass="cssPager" ForeColor="#333333" 
                                HorizontalAlign="Center" />
                            <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="Navy" />
                            <HeaderStyle BackColor="#FF9933" Font-Bold="True" ForeColor="White" />
                            <AlternatingRowStyle BackColor="White" />
                        </asp:GridView>
                    </td>
                </tr>
            </table>
            <div align="right">
                   <asp:Label ID="lblTotal" runat="server" Font-Bold="True" ForeColor="#003300"></asp:Label>
             </div>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>

